package com.luanye.enjoy.exception;

import com.luanye.enjoy.enums.StatusCode;
import lombok.Getter;

@Getter
public class APIException extends RuntimeException{

    private Integer code;

    private String message;

    public APIException(StatusCode status){
        super(status.getMsg());
        this.code = status.getCode();
        this.message = status.getMsg();
    }
}
